/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.agi.util.fft;

/**
 *
 * @author Renato
 */
public class FftMax extends Fft {
    private double[] dataRetorno;
    private double[] data;
    private Complex[] complexData;
    public FftMax(MaxData maxData){
        this.data=maxData.getData();
        complexData=new Complex[data.length];
        for(int i=0;i<data.length;i++){
            complexData[i]=new Complex(0,0);
        }
        dataRetorno=new double[data.length];
    }
    
    public void calcular(){
        for(int i=0; i<data.length;i++){
            complexData[i].setRe(data[i]);
        }
        super.calcular(complexData);
        for(int i=0; i<data.length;i++){
            dataRetorno[i]=super.retorno[i].re();            
        }
    }
}
